2.1 Logging for MyID Desktop

You can set up your MyID Desktop application to write debug information to a log file. You may need to provide this information to Intercede customer support.

To set up the logging, you must create a text file in the application folder with the relevant information.

To switch logging on:

  1. On the client PC, if it does not already exist, create a Debug.config file in the following folder:

    C:\Program Files (x86)\Intercede\MyIDDesktop\

  2. Using a text editor, open the Debug.config file.

    Note: Make the changes to the config file exactly as shown. The case is important.

    <Debug>
      <add key="Enabled"                   value="true" />
      <add key="DebugProvider"             value="CodeHelpers.DebugTrace" />
      <add key="LogFirstChangeExceptions"  value="true" />
      <add key="LogUnhandledExceptions"    value="false" />
      <add key="LogThreadingExceptions"    value="false" />
    </Debug>

  3. You can switch logging on and off by editing the following:

    • Enabled – set to true to enable logging, or false to disable logging.

  4. Save the configuration file.

  5. On the client PC, back up the MyIDDesktop.exe.config file in the following folder:

    C:\Program Files (x86)\Intercede\MyIDDesktop\

  6. Using a text editor, open the MyIDDesktop.exe.config file.

    Note: Make the changes to the config file exactly as shown. The case is important.

  7. Within the root <configuration> node of the file, add the following immediately before the line containing the </configuration> closing tag:

    <log4net>
     <root>
      <level value="ALL" />
      <appender-ref ref="RollingFileAppender" />
     </root>
     <appender name="RollingFileAppender" type="log4net.Appender.RollingFileAppender">
     <file type="log4net.Util.PatternString" value="LogFile.xml"/>
      <appendToFile value="true"/>
      <datePattern value="yyyyMMdd"/>
      <rollingStyle value="Size"/>
      <maxSizeRollBackups value="10"/>
      <maximumFileSize value="10000KB"/>
      <layout type="log4net.Layout.XmlLayoutSchemaLog4j">
       <locationInfo value="true"/>
      </layout>
     </appender>
    </log4net>
    <Debug configSource="Debug.Config" />

    Note: The following line contains the name of the file to which the log is written:

    <file type="log4net.Util.PatternString" value="LogFile.xml"/>

    If you do not specify a path, the file is written to the program folder. Make sure that the user running MyID Desktop has permission to write to this folder. If the user does not have permission to write to the program folder, specify a path to a file that the user does have permissions to; for example:

    <file type="log4net.Util.PatternString" value="C:\Logs\log.xml"/>

  8. Save the config file.